home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / lang / c++-part2 / 18108 < prev    next >
Encoding:
Internet Message Format  |  1996-08-05  |  1.3 KB

  1. Path: janus.cqu.edu.au!usenet
  2. From: Mutchg@Topaz.Cqu.Edu.Au (G.D.Mutch)
  3. Newsgroups: comp.lang.c++
  4. Subject: NEED HELP WITH ABSOLUTE ADDRESSING
  5. Date: 18 Apr 1996 22:46:17 GMT
  6. Organization: CQ University
  7. Message-ID: <4l6gnp$38c@janus.cqu.edu.au>
  8. NNTP-Posting-Host: 138.77.57.12
  9. X-Newsreader: WinVN 0.92.6+
  10.  
  11. Please !
  12. Can Anyone tell me how to assign an absolute address to a variable,
  13. or get the variable to point to 0x378 ?
  14.  
  15. I wish to access the 24 bits at the parallel printer port directly.
  16. and load the data directly. 
  17.  
  18. I wish to get the compiler to assign 0x378 to the variable address.
  19.  Eg. 
  20.  
  21.  int &Base0 = 0x378h;        
  22.  
  23.  int *Base0 = 0x378h;        
  24.  
  25.  int Base0 = 0x378h;        
  26.  
  27. None of these code fragments will not assign 0x378h to the absolute address 
  28. of Base0. I find this odd... what am I overlooking ?
  29.  
  30. If this fails I will resort to inline assembler code .
  31.  
  32. I'm using turbo c++ 3.1 at the moment.
  33.  
  34.  
  35.  
  36. Also can anybody give me the source code in load Gif,Bmp,Pcx ,etc graphic
  37. files to the screen. Anything would be helpful... preferably with 
  38. meaningful comments in the code, so as I can learn how its done in C++. 
  39.  
  40.  
  41. Also how do I use the project organiser with turbo C++ 3.1 ?
  42. I have no idea what I'm suppose to do to use it... an example with 
  43. the explaination would be nice ? 
  44.  
  45.  
  46. (Please excuse me, I'm still converting over from Pascal)
  47.  
  48. Thanks in advance
  49. G.D.Mutch
  50.  
  51.